package com.company;

public class Main {

    public static void main(String[]args) {
        People p1 = new Student("张某", 98700, "模电实验室", "生物实验室");        //学生A负责实验室
        People p2 = new Student("李某", 56700, "化学实验室", "物理演示实验室");     //学生B负责实验室
        System.out.println("学生信息：");
        System.out.println(p1);
        System.out.println(p2);
        lab r1 = new lab("模电实验室", "优秀");
        lab r2 = new lab("生物实验室", "及格");
        lab r3 = new lab("化学实验室", "不及格");
        lab r4 = new lab("物理演示实验室", "及格");

        System.out.println("实验室：");       //实验室等级报表
        System.out.println(r1);
        System.out.println(r2);
        System.out.println(r3);
        System.out.println(r4);

        System.out.println("        ");
        System.out.println("学生实验室等级评级：");         //学生实验室等级评级
        System.out.println("张某等级为" + r1.level + "的实验室为:" + p1.tab1);
        System.out.println("张某等级为" + r2.level + "的实验室为:" + p1.tab2);
        System.out.println("李某等级为" + r3.level + "的实验室为:" + p2.tab1);
        System.out.println("李某等级为" + r4.level + "的实验室为:" + p2.tab2);

        try {                                                   //周收入和总收入计算
            double result1 = Tex.sum(800, 200);
            System.out.println("张某一周的收入为:" + result1);
            p1.income = result1;
            p1.income = p1.income * 18;
            System.out.println("张某的总收入为：" + p1.income);
            double result3 = Tex.avg(p1.income);
            System.out.println("张某税后的收入为：" + result3);
            double result2 = Tex.sum(70, 200);

            System.out.println("李某一周的收入为:" + result2);
            p2.income = result2;
            p2.income = p2.income * 18;
            System.out.println("李某的总收入为:" + p2.income);
            double result4 = Tex.avg(p2.income);
            System.out.println("李某税后的收入为:" + result4);

        } catch (Exception9 e) {                       //系统特殊反馈（输入负数，不交税）
            System.out.println(e);
        }
    }
}